find_package(Qt4)

if (NOT QT_FOUND)
	message (WARNING "Qt4 not found. The sub-project is skipped")
	return ()
endif()

SET(prog_SOURCES main.cpp)
SET(prog_HEADERS main.h)
SET(prog_RESOURCES )

QT4_WRAP_CPP(prog_HEADERS_MOC ${prog_HEADERS})
# QT4_WRAP_UI(prog_FORMS_HEADERS ${prog_FORMS})
# QT4_ADD_RESOURCES(prog_RESOURCES_RCC ${prog_RESOURCES})

INCLUDE(${QT_USE_FILE})
ADD_DEFINITIONS(${QT_DEFINITIONS})

ADD_EXECUTABLE(how-to-emit-cross-thread-signal-in-qt ${prog_SOURCES} ${prog_HEADERS}
    ${prog_HEADERS_MOC}
    ${prog_FORMS_HEADERS} 
    ${prog_RESOURCES_RCC})
TARGET_LINK_LIBRARIES(how-to-emit-cross-thread-signal-in-qt ${QT_LIBRARIES})

source_group("Generated Files" FILES ${prog_FORMS_HEADERS} ${prog_HEADERS_MOC} ${prog_RESOURCES_RCC})

